
package com.welsy.stats.model
{
	import com.welsy.stats.Stats;
	import mx.collections.ArrayCollection;
	import com.adobe.cairngorm.model.ModelLocator;
	import com.welsy.iter.vo.IterVO;
	import com.welsy.usermgt.vo.ClassVO;
	import com.welsy.stats.vo.IterClassVO;
	import com.welsy.stats.vo.IterElementStatsVO;
	import com.welsy.stats.view.classview.CourseView;
	import com.welsy.stats.view.classview.CourseExplodableView;
	import com.welsy.stats.view.classview.TestView;
	import com.welsy.authoring.vo.CourseVO;
	import com.welsy.stats.view.courseview.CourseTestView;
	   
     
   [Bindable]
   public class StatsModelLocator implements ModelLocator
   {
      private static var modelLocator : StatsModelLocator;
      
      public static function getInstance() : StatsModelLocator 
      {
      	if ( modelLocator == null )
      	{
      		modelLocator = new StatsModelLocator();
      	}
      		
      	return modelLocator;
      }
      
      //Constructor should be private but current AS3.0 does not allow it yet (?)...
      public function StatsModelLocator() 
      {	
         if ( modelLocator != null )
         {
         	throw new Error( "Only one StatsModelLocator instance should be instantiated" );	
         }
         
         //assets = new CairngormCourseAssets();
      }
    
    
		public var iterClasses : ArrayCollection = null; //ClassVO
		public var currentIterClasses : ArrayCollection = null; //ClassVO
		public var briefUserResults : ArrayCollection = null; //BriefUserResultsVO
		
		public var itinera : ArrayCollection = null;
		
		public var currentIter : IterVO; //for the "Iter" view
		public var currentClass : IterClassVO; //for the "Iter" view
		
		public var iterList : ArrayCollection = null; //Quantità
		public var iterList2 : ArrayCollection = null; //Risultati
		public var users : String; //The user number to be show on the rightr of classes
		public var currentIterClass : ClassVO;//for the "Classe" view
		
		public var currentCourse : CourseExplodableView; //The current selected exploded course in "Classi"
		public var currentTest : TestView; //The current selected exploded test in "Classi"
		
		public var courses : ArrayCollection = null;
		public var currentCoursesCourse : CourseVO; //for "Corsi" view
		public var coursesClassTestsA : ArrayCollection = null;
		public var coursesClassTestsB : ArrayCollection = null; //TestView
		public var currentCourseTest : CourseTestView;//The current selected exploded text for "Corsi"
		public var courseUsers : String;
		public var courseClasses : ArrayCollection;
 
   }

}
